﻿<%@ Page Title="GotPink Administrative Panel" Language="VB" MasterPageFile="~/admin/AdminMaster.master" AutoEventWireup="false" CodeFile="AdminUsers.aspx.vb" Inherits="admin_AdminPanel" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

    <asp:GridView ID="GridView1" runat="server" AllowPaging="True" CssClass="Gridview"
        AutoGenerateColumns="False" DataKeyNames="CustomerID" 
        DataSourceID="AccessDataSource1">
        <Columns>
            <asp:BoundField DataField="CustomerID" HeaderText="CustomerID" 
                InsertVisible="False" ReadOnly="True" SortExpression="CustomerID" />
            <asp:BoundField DataField="FirstName" HeaderText="FirstName" 
                SortExpression="FirstName" />
            <asp:BoundField DataField="LastName" HeaderText="LastName" 
                SortExpression="LastName" />
            <asp:BoundField DataField="EmailAddress" HeaderText="EmailAddress" 
                SortExpression="EmailAddress" />
            <asp:BoundField DataField="PhoneNumber" HeaderText="PhoneNumber" 
                SortExpression="PhoneNumber" />
        </Columns>
    </asp:GridView>
    <asp:AccessDataSource ID="AccessDataSource1" runat="server" 
        DataFile="~/App_Data/GotPink.accdb" 
        DeleteCommand="DELETE FROM [Customers] WHERE [CustomerID] = ?" 
        InsertCommand="INSERT INTO [Customers] ([CustomerID], [FirstName], [LastName], [EmailAddress], [PhoneNumber]) VALUES (?, ?, ?, ?, ?)" 
        SelectCommand="SELECT [CustomerID], [FirstName], [LastName], [EmailAddress], [PhoneNumber] FROM [Customers]" 
        UpdateCommand="UPDATE [Customers] SET [FirstName] = ?, [LastName] = ?, [EmailAddress] = ?, [PhoneNumber] = ? WHERE [CustomerID] = ?">
        <DeleteParameters>
            <asp:Parameter Name="CustomerID" Type="Int32" />
        </DeleteParameters>
        <InsertParameters>
            <asp:Parameter Name="CustomerID" Type="Int32" />
            <asp:Parameter Name="FirstName" Type="String" />
            <asp:Parameter Name="LastName" Type="String" />
            <asp:Parameter Name="EmailAddress" Type="String" />
            <asp:Parameter Name="PhoneNumber" Type="String" />
        </InsertParameters>
        <UpdateParameters>
            <asp:Parameter Name="FirstName" Type="String" />
            <asp:Parameter Name="LastName" Type="String" />
            <asp:Parameter Name="EmailAddress" Type="String" />
            <asp:Parameter Name="PhoneNumber" Type="String" />
            <asp:Parameter Name="CustomerID" Type="Int32" />
        </UpdateParameters>
    </asp:AccessDataSource>
    <br />
    <br />

</asp:Content>

